if not exists (select * from syscolumns where id=object_id('tb_ErpOrdersPhotography') and name='Ordpg_CostPrice') begin alter table tb_ErpOrdersPhotography add Ordpg_CostPrice decimal(18, 2) NULL end IF NOT EXISTS (SELECT * FROM ::fn_listextendedproperty(N'MS_Description' , N'SCHEMA',N'dbo', N'TABLE',N'tb_ErpOrdersPhotography', N'COLUMN',N'Ordpg_CostPrice')) EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'景点成本价' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'tb_ErpOrdersPhotography', @level2type=N'COLUMN',@level2name=N'Ordpg_CostPrice' GO if not exists (select * from syscolumns where id=object_id('tb_ErpCustomer') and name='Cus_IDNumber') begin alter table tb_ErpCustomer add Cus_IDNumber nvarchar(2000) NULL end IF NOT EXISTS (SELECT * FROM ::fn_listextendedproperty(N'MS_Description' , N'SCHEMA',N'dbo', N'TABLE',N'tb_ErpCustomer', N'COLUMN',N'Cus_IDNumber')) EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'客户身份证号' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'tb_ErpCustomer', @level2type=N'COLUMN',@level2name=N'Cus_IDNumber' GO if not exists (select * from syscolumns where id=object_id('tb_ErpCompanyInfo') and name='Company_ChildReserveExplain') begin alter table tb_ErpCompanyInfo add Company_ChildReserveExplain nvarchar(2000) NULL end IF NOT EXISTS (SELECT * FROM ::fn_listextendedproperty(N'MS_Description' , N'SCHEMA',N'dbo', N'TABLE',N'tb_ErpCompanyInfo', N'COLUMN',N'Company_ChildReserveExplain')) EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'预约儿童单说明' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'tb_ErpCompanyInfo', @level2type=N'COLUMN',@level2name=N'Company_ChildReserveExplain' GO if not exists (select * from syscolumns where id=object_id('tb_ErpCompanyInfo') and name='Company_PortraitReserveExplain') begin alter table tb_ErpCompanyInfo add Company_PortraitReserveExplain nvarchar(2000) NULL end IF NOT EXISTS (SELECT * FROM ::fn_listextendedproperty(N'MS_Description' , N'SCHEMA',N'dbo', N'TABLE',N'tb_ErpCompanyInfo', N'COLUMN',N'Company_PortraitReserveExplain')) EXEC sys.sp_addextendedproperty @name=N'MS_Description', @value=N'预约写真单说明' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'TABLE',@level1name=N'tb_ErpCompanyInfo', @level2type=N'COLUMN',@level2name=N'Company_PortraitReserveExplain' GO update tb_ErpOrderProductList set OPlist_ReservationTakeName = '' where OPlist_ReservationTakeName is null update tb_ErpOrderProductList set OPlist_ArrangeNmae = '' where OPlist_ArrangeNmae is null update tb_ErpOrderProductList set OPlist_ArrangeRemark = '' where OPlist_ArrangeRemark is null update tb_ErpOrderProductList set OPlist_PickupStatus = '0' where OPlist_PickupStatus is null update tb_ErpOrderProductList set OPlist_PickupName = '' where OPlist_PickupName is null update tb_ErpOrderProductList set OPlist_PickupQuantity = 0 where OPlist_PickupQuantity is null update tb_ErpOrderProductList set OPlist_PickupRemark = '' where OPlist_PickupRemark is null update tb_ErpOrderProductList set OPlist_SendNumber = '' where OPlist_SendNumber is null update tb_ErpOrderProductList set OPlist_SendStatus = '0' where OPlist_SendStatus is null update tb_ErpOrderProductList set OPlist_SendVendor = '' where OPlist_SendVendor is null update tb_ErpOrderProductList set OPlist_SendName = '' where OPlist_SendName is null update tb_ErpOrderProductList set OPlist_ReworkStatus = '' where OPlist_ReworkStatus is null update tb_ErpOrderProductList set OPlist_ReworName = '' where OPlist_ReworName is null update tb_ErpOrderProductList set OPlist_ReworQuantity = 0 where OPlist_ReworQuantity is null update tb_ErpOrderProductList set OPlist_ReworkRemark = '' where OPlist_ReworkRemark is null update tb_ErpOrderProductList set OPlist_CompletedStatus = '0' where OPlist_CompletedStatus is null update tb_ErpOrderProductList set OPlist_CompletedName = '' where OPlist_CompletedName is null update tb_ErpOrderProductList set OPlist_CompletedQuantity = 0 where OPlist_CompletedQuantity is null update tb_ErpOrderProductList set OPlist_SelectFilmProductLog = '' where OPlist_SelectFilmProductLog is null update tb_ErpOrderProductList set OPlist_CreateName = '' where OPlist_CreateName is null